import { invoke } from '@tauri-apps/api/core';


const call = function(command, args = {}, options = {}) {
    try {
        const result = invoke(command, args, options);
        return {
            success: true,
            data: result,
            error: null
        };
    } catch (error) {
        return {
            success: false,
            data: null,
            error: error.message || '调用失败'
        };
    }
}

export {
    call
}